<?php
declare (strict_types = 1);

namespace app\listener\callback;

use app\service\logic\common\order\OrderMultiService;
use Exception;
use think\facade\Log;

class OrderMultiPaySuccessListener
{
    /**
     * @param $argc
     * @return bool
     */
    public function handle($argc)
    {
        try {
            invoke(OrderMultiService::class)->paySuccess($argc['out_trade_no'], $argc['trade_status']);
        } catch (Exception $e) {
            Log::debug('OrderMultiPaySuccessListenerException: out_trade_no=' . $argc['out_trade_no'] . ', message=' . $e->getMessage());
            return true;
        }
    }
}
